package com.echoesnet.echoesshortvideo.Beans;

import android.databinding.BaseObservable;
import android.databinding.Bindable;

import com.echoesnet.echoesshortvideo.BR;

public class IncludeNavBarBean extends BaseObservable {
    private String textHeadline = "";
    private String textLeft1 = "\ue908";
    private String textLeft2 = "";
    private String textRight = "";
    private boolean showLeft = false;
    private boolean showLeft2 = false;
    private boolean showRight = false;

    private int textHeadlineBG;
    private boolean showHeadlineBG = false;

    public IncludeNavBarBean() {
    }

    public IncludeNavBarBean(String textHeadline, String textLeft1, String textLeft2, String textRight) {
        this.textHeadline = textHeadline;
        this.textLeft1 = textLeft1;
        this.textLeft2 = textLeft2;
        this.textRight = textRight;

        this.showLeft = !"".equals(textLeft1);
        this.showLeft2 = !"".equals(textLeft2);
        this.showRight = !"".equals(textRight);
        this.showHeadlineBG = "".equals(textHeadline);
    }

    public IncludeNavBarBean(String textHeadline, boolean showLeft) {
        this.textHeadline = textHeadline;
        this.textLeft1 = "";
        this.textLeft2 = "";
        this.textRight = "";

        this.showLeft = showLeft;
        this.showLeft2 = !"".equals(textLeft2);
        this.showRight = !"".equals(textRight);
        this.showHeadlineBG = "".equals(textHeadline);
    }

    public IncludeNavBarBean(boolean showLogo, boolean showLeft) {
        this.textHeadline = "";
        this.textLeft1 = "";
        this.textLeft2 = "";
        this.textRight = "";

        this.showLeft = showLeft;
        this.showLeft2 = !"".equals(textLeft2);
        this.showRight = !"".equals(textRight);
        this.showHeadlineBG = showLogo;
    }

    @Bindable
    public boolean isShowLeft() {
        return showLeft;
    }

    public void setShowLeft(boolean showLeft) {
        this.showLeft = showLeft;
        notifyPropertyChanged(BR.showLeft);
    }

    public void setShowLeft2(boolean showLeft2) {
        this.showLeft2 = showLeft2;
        notifyPropertyChanged(BR.showLeft2);

    }

    public void setShowRight(boolean showRight) {
        this.showRight = showRight;
        notifyPropertyChanged(BR.showRight);

    }

    public void setTextHeadline(String textHeadline) {
        this.textHeadline = textHeadline;
        notifyPropertyChanged(BR.textHeadline);
    }

    public void setTextLeft1(String textLeft1) {
        this.textLeft1 = textLeft1;
        notifyPropertyChanged(BR.textLeft1);


    }

    public void setTextLeft2(String textLeft2) {
        this.textLeft2 = textLeft2;
        notifyPropertyChanged(BR.textLeft2);

    }

    public void setTextRight(String textRight) {
        this.textRight = textRight;
        notifyPropertyChanged(BR.textRight);
    }



    public void setShowHeadlineBG(boolean showHeadlineBG) {
        this.showHeadlineBG = showHeadlineBG;
        notifyPropertyChanged(BR.showHeadlineBG);

    }

    @Bindable
    public boolean isShowLeft2() {
        return showLeft2;
    }

    @Bindable
    public boolean isShowRight() {
        return showRight;
    }

    @Bindable
    public String getTextHeadline() {
        return textHeadline;
    }

    @Bindable
    public String getTextLeft1() {
        return textLeft1;
    }

    @Bindable
    public String getTextLeft2() {
        return textLeft2;
    }

    @Bindable
    public String getTextRight() {
        return textRight;
    }

    @Bindable
    public boolean isShowHeadlineBG() {
        return showHeadlineBG;
    }
}